<template>
  <div class="medichaineMain">
    <div class="medichaineMain_top">地图</div>
    <div class="medichaineMain_bottom">
      <van-tabs v-model:active="active">
        <van-tab title="已分好药">
          <div class="medichaineMain_item" style="text-align: center">
            <span>订单</span>
            <span @click="totakingQRcode">取药二维码</span>
          </div>
        </van-tab>
        <van-tab title="未分好药">内容 2</van-tab>
      </van-tabs>
    </div>
  </div>
</template>

<script>
export default {
  name: "medichaineMain",
  data() {
    return {
      active: 0,
    };
  },
  methods: {
    totakingQRcode() {
      this.$router.push({ path: "/home/medicine/takeQrCode" });
    },
  },
};
</script>

<style lang="scss" scope>
.medichaineMain {
  height: 100%;
  &_item {
    margin: 20px 0;
    & span {
      margin: 0 20px;
    }
  }
  &_bottom {
    & .van-tab--active {
      color: #0b51ca;
    }
    & .van-tabs__line {
      background: #3072e0;
      width: 80px;
      height: 2px;
    }
  }
  &_top {
    height: 220px;
    background-color: red;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #666;
  }
}
</style>
